<template>
  <div id="app">
    <!-- 顶部导航条和搜索 -->
    <header-nav />
    <!-- 路由页面 -->
    <keep-alive>
      <router-view />
    </keep-alive>
    <!-- 返回顶部 -->
    <el-backtop>
      <div class="backTop">返回顶部</div>
    </el-backtop>
  </div>
</template>

<script>
  import headerNav from '@/components/HeaderNav'
  export default {
    components: {
      headerNav
    }
  }
</script>

<style>
  * {
    margin: 0;
    padding: 0;
  }

  #app {
    font-family: Avenir, Helvetica, Arial, sans-serif;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    text-align: center;
    color: #2c3e50;
  }

  .backTop {
    font-size: 13px;
    background: purple;
    border-radius: 5px;
    padding: 7px;
    color: white;
    opacity: 0.8;
  }
</style>